using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;using Maxleaf.EDI.Domain.K3;

namespace Maxleaf.EDI.DataAccess.K3
{
    public class t_GroupAccessTypeMap : EntityTypeConfiguration<t_GroupAccessType>
    {
        public t_GroupAccessTypeMap()
        {
            // Primary Key
            this.HasKey(t => t.FGroupID);

            // Properties
            this.Property(t => t.FGroupID)
                .HasDatabaseGeneratedOption(DatabaseGeneratedOption.None);

            this.Property(t => t.FSubSys)
                .HasMaxLength(20);

            this.Property(t => t.FAccess)
                .HasMaxLength(20);

            this.Property(t => t.FSubSys_Cht)
                .HasMaxLength(255);

            this.Property(t => t.FSubSys_en)
                .HasMaxLength(255);

            this.Property(t => t.FAccess_Cht)
                .HasMaxLength(255);

            this.Property(t => t.FAccess_en)
                .HasMaxLength(255);

            // Table & Column Mappings
            this.ToTable("t_GroupAccessType");
            this.Property(t => t.FGroupID).HasColumnName("FGroupID");
            this.Property(t => t.FSubSys).HasColumnName("FSubSys");
            this.Property(t => t.FAccess).HasColumnName("FAccess");
            this.Property(t => t.FMask).HasColumnName("FMask");
            this.Property(t => t.FSubSys_Cht).HasColumnName("FSubSys_Cht");
            this.Property(t => t.FSubSys_en).HasColumnName("FSubSys_en");
            this.Property(t => t.FAccess_Cht).HasColumnName("FAccess_Cht");
            this.Property(t => t.FAccess_en).HasColumnName("FAccess_en");
        }
    }
}
